package file;

import java.io.File;

public class DelectDirDemo {
    public static void main(String[] args) {
        //删除当前目录下的demo目录
        File dir = new File("./demo");
        if (dir.exists()) {
            /*

            */
            dir.delete();
            System.out.println("该目录已删除");
        }else {
            System.out.println("该目录不存在");
        }

        File dirs = new File("./a");
        if (dirs.exists()) {
            dirs.delete();
        }else {

        }
    }
}
